import { Module } from '@nestjs/common';
import buildEnv from "./env";
import {BookManagerModule} from "./book_manager/module";


const buildEnv = function() {
    let env = {
        "mongo_host": "118.24.98.157",
        "mongo_port": 28001,
        "mongo_db_name": "book",

        "redis_host": "118.24.98.157",
        "redis_port": 8999
    };

    let key: string;
    for (key in env) {
        process.env[key]= `${env[key]}`;
    }
};
if (process.env.OS.startsWith("Win")) {
    buildEnv();
}

@Module({
  imports: [
      BookManagerModule
  ]
})
export class AppModule {}
